package com.patttern.creativity.singlenton;

/**
 * @Author: root
 * @Date: 2018/12/3 21:10
 * 静态内部类单例模式
 */
public class Singleton04 {


    private Singleton04() {
    }

    private static class SingletonClassInstance {
        private static final Singleton04 instance = new Singleton04();
    }

    public static Singleton04 getInstance() {
        return SingletonClassInstance.instance;
    }
}
